<script setup>
import { formatTime } from '../../../utils';
const props = defineProps({
	item: {
		type: Object,
		default: () => ({})
	}
});
</script>

<template>
	<view class="com-box item">
		<view class="title">{{ item.title }}</view>
		<view class="info">{{ item.info }}</view>
		<view class="time">{{ formatTime(item.creatTime) }}</view>
	</view>
</template>

<style lang="scss" scoped>
.item {
	background-color: #fff;
	border-radius: 17rpx;
	min-height: 90rpx;
	padding: 20rpx;
	font-size: 24rpx;
	margin-top: 20rpx !important;
	box-shadow: 0rpx 8rpx 10rpx #f1f2f3;
	.title {
		font-size: 28rpx;
		margin-bottom: 15rpx;
		font-weight: 600;
	}
	.info {
		width: 100%;
		color: #686868;
		display: -webkit-box;
		-webkit-box-orient: vertical;
		-webkit-line-clamp: 3;
		/* 限制显示的行数为3行 */
		overflow: hidden;
		/* 隐藏超出部分 */
		text-overflow: ellipsis;
	}

	.time {
		margin-top: 15rpx;
		color: #bdbdbd;
	}
}
</style>
